
#ifndef MAINHANDLER_H
#define MAINHANDLER_H

#include <BMap>
#include <BCamera>
#include <BLight>
#include <BSphereHandler>

using namespace BWE;

class MainHandler : public BSphereHandler
{
public:
	MainHandler();
	~MainHandler();

	void setTargetCamera(BCamera* camera);

protected:
	void slotCameraDirty();

protected:
	virtual void paint(BPainter& painter);
	virtual void render(BRender& render);
	
private:
	BCameraHolder				_camera;
	BHolder<BVectorArray>		_frustumPoints;
	BHolder<BLightArray>		_enableLights;
	BHolder<BNodeArray>			_visualNodes;
	BHolder<BMap<BShape*, BBox>>		_shapeQueue;
	BHolder<BMap<BShape*, BBox>>		_transShapeQueue;
};

#endif
